package com.cloud.logger.zchain.zchainserver.mail;


import com.cloud.logger.zchain.core.common.base.ResultMessage;
import com.cloud.logger.zchain.zchainserver.base.PagePo;
import com.cloud.logger.zchain.zchainserver.entity.AngelaLoggerProjectNode;
import com.cloud.logger.zchain.zchainserver.entity.MailFailure;
import com.cloud.logger.zchain.zchainserver.entity.MailSuccess;
import org.springframework.data.domain.Page;

/**
 * 浙江卓锐科技股份有限公司
 *
 * @author zhengyt
 * @create 2017/11/10
 * @description
 */
public interface MailService {

    ResultMessage<MailSuccess> save(MailSuccess mailSuccess);

    ResultMessage sendMail(MailSuccess mailSuccess);

    ResultMessage<MailSuccess> getMail(String id, String type);

    ResultMessage<MailSuccess> update(MailSuccess mailSuccess);

    ResultMessage<MailSuccess> select(MailSuccess mailSuccess);

    ResultMessage removeById(Long id);

    ResultMessage sendHtmlMail(MailInfo info, AngelaLoggerProjectNode node);

    Page findMailSuccess(PagePo<MailSuccess> pageInfo) throws Exception;

    Page findMailFailure(PagePo<MailFailure> pageInfo) throws Exception;
}
